var path = require('path')
var copydir = require('copy-dir')

const fromPath = '_posts'
const targetPath = 'public/md-images'

copydir.sync(fromPath, targetPath, {
  filter: function (stat, filepath) {
    if (stat === 'file' && path.extname(filepath) === '.md') {
      return false
    }
    return true
  },
})
